using B.S.Requst;
using B.S.Data.MES.API.Dto.InvoiceDTO;
using MediatR;
using System;
using System.Collections.Generic;

namespace B.S.Data.MES.API.Applications.B.S.KApplications.Query.InvoiceQuery
{
    /// <summary>
    /// 获取销售发票查询
    /// 用于处理销售发票的查询请求
    /// </summary>
    public class GetSalesInvoiceQuery : IRequest<APIRequst<APIPageing<List<SalesInvoiceDTO>>>>
    {
        /// <summary>
        /// 页码
        /// 默认值为1
        /// </summary>
        public int PageIndex { get; set; } = 1;

        /// <summary>
        /// 每页条数
        /// 默认值为10
        /// </summary>
        public int PageSize { get; set; } = 10;

        /// <summary>
        /// 发票编号
        /// 用于精确查询
        /// </summary>
        public string? InvoiceNo { get; set; }

        /// <summary>
        /// 关键词
        /// 用于模糊查询备注等字段
        /// </summary>
        public string? Keyword { get; set; }

        /// <summary>
        /// 发票状态
        /// 0：待开具，1：已开具，2：已作废，3：已红冲
        /// -1表示不筛选
        /// </summary>
        public int InvoiceStatus { get; set; } = -1;

        /// <summary>
        /// 客户ID
        /// -1表示不筛选
        /// </summary>
        public int CustomerId { get; set; } = -1;

        /// <summary>
        /// 开始日期
        /// 用于筛选指定日期范围内的发票
        /// </summary>
        public DateTime? StartDate { get; set; }

        /// <summary>
        /// 结束日期
        /// 用于筛选指定日期范围内的发票
        /// </summary>
        public DateTime? EndDate { get; set; }
    }
}